x86: fix the potential of encountering panic "IO-APIC + timer doesn't work! ..."
authorKeir Fraser <keir.fraser@citrix.com>
Thu, 11 Dec 2008 11:40:10 +0000 (11:40 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Thu, 11 Dec 2008 11:40:10 +0000 (11:40 +0000)
commit849bd717c230fe8208cca3ef3be5f8e40735b755
tree624c23056a40922fc992946a38f8bc58f835bdac
parent3bc61439add8aa6386afcff33a46a85d2247b960
x86: fix the potential of encountering panic "IO-APIC + timer doesn't work! ..."

Signed-off-by: Jan Beulich <jbeulich@novell.com>
Linux commit:
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=4aae07025265151e3f7041dfbf0f529e122de1d8

x86: fix "Kernel panic - not syncing: IO-APIC + timer doesn't work!"

Under rare circumstances we found we could have an IRQ0 entry while we
are in the middle of setting up the local APIC, the i8259A and the
PIT. That is certainly not how it's supposed to work! check_timer()
was supposed to be called with irqs turned off - but this eroded away
sometime in the past. This code would still work most of the time
because this code runs very quickly, but just the right timing
conditions are present and IRQ0 hits in this small, ~30 usecs window,
timer irqs stop and the system does not boot up. Also, given how early
this is during bootup, the hang is very deterministic - but it would
only occur on certain machines (and certain configs).

The fix was quite simple: disable/restore interrupts properly in this
function. With that in place the test-system now boots up just fine.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
xen/arch/x86/io_apic.c